from django.db import models

# Create your models here.
class BaseInfo(models.Model):
    studentId=models.CharField(max_length=30,primary_key=True)
    name=models.CharField(max_length=30)
    age=models.IntegerField()

class Hobby(models.Model):
    hobbyId=models.IntegerField(primary_key=True)
    hobby=models.CharField(max_length=50)
    student=models.ForeignKey(BaseInfo,on_delete=models.CASCADE)
    
